<!--  -->
<template>
  <wd-button
    :type="type"
    :size="size"
    :round="false"
    :open-type="openType"
    :custom-class="customClass"
    :disabled="disabled"
    :plain="plain"
    @click="$emit('click')"
    @getphonenumber="(e) => $emit('getphonenumber', e)"
  >
    <slot></slot>
  </wd-button>
</template>

<script lang="ts" setup>
  import { ButtonOpenType } from '@uni-helper/uni-types/index';

  defineProps({
    type: {
      type: String,
      default: 'primary',
    },
    size: {
      type: String,
      default: 'large',
    },
    openType: {
      type: String as PropType<ButtonOpenType>,
      default: '',
    },
    customClass: {
      type: String,
      default: '',
    },
    block: {
      type: Boolean,
      default: false,
    },
    disabled: {
      type: Boolean,
      default: false,
    },
    plain: {
      type: Boolean,
      default: false,
    },
  });
  defineEmits(['click', 'getphonenumber']);
</script>

<style lang="scss" scoped></style>
